class lzu::auth (
$sudo_users = ["optlzu"],
) {
  package { 'ypbind':
    ensure  => "installed",
    require => Yumrepo['site'],
  }->
  class { 'authconfig' :
    nis        => true,
    nisdomain  => "lzuhep.lzu.edu.cn",
    nisserver  => "192.168.1.100",
    cache      => true,
    require    => Package['ypbind'],
  }~>
  service { 'ypbind':
    ensure  => running,
    hasrestart => true,
    hasstatus  => true,
  }
  $admins_alias = join($sudo_users,",")

  sudo::conf { 'admins':
    priority  => 10,
    template  => "${module_name}/admins.erb",
  }
}
